<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>
<%@ page import="com.fengke.portal.config.HostConfig" %>
<%
	HostConfig hostConfig = (HostConfig) request.getSession().getServletContext().getAttribute("hostConfig");
%>
<!DOCTYPE html>
<html>
<head>
<base href="<%=hostConfig.getPortalHost() %>" />
<title>
	<s:if test='productVO.productModel.name != null && !"".equals(productVO.productModel.name.trim())'>
		生成订单-<s:property value="productVO.productModel.name" />
	</s:if>
	<s:else><%=hostConfig.getWebSiteName() %></s:else>
</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1, maximum-scale=1, user-scalable=no">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<link href="resources/travel/weixin/css/bootstrap.min.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/css/bootstrap-theme.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/css/font-awesome.min.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/css/messenger.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/css/image.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/css/travel.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/jslib/icheck/skins/flat/blue.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/jslib/jquery-validation-engine/css/validationEngine.jquery.css" rel="stylesheet" media="screen">
<link href="resources/travel/weixin/jslib/mobiscroll-calendar/css/mobiscroll.custom-2.14.4.min.css" rel="stylesheet" media="screen">

<script src="resources/travel/weixin/js/jquery.min.js"></script>
<script src="resources/travel/weixin/js/bootstrap.min.js"></script>
<script src="resources/travel/weixin/js/bootbox.js"></script>
<script src="resources/travel/weixin/js/messenger.js"></script>
<script src="resources/travel/weixin/js/messenger-theme-future.js"></script>
<script src="resources/travel/weixin/js/holder.js"></script>

<script src="resources/travel/weixin/jslib/icheck/js/jquery.icheck.min.js"></script>
<script src="resources/travel/weixin/jslib/jquery-validation-engine/js/languages/jquery.validationEngine-zh_CN.js"></script>
<script src="resources/travel/weixin/jslib/jquery-validation-engine/js/jquery.validationEngine.js"></script>
<script src="resources/travel/weixin/jslib/mobiscroll-calendar/js/mobiscroll.custom-2.14.4.min.js"></script>
<script src="resources/travel/weixin/js/application.js"></script>
<script type="text/javascript" src="resources/shop/js/common.js"></script>

<style>
a:hover {
	text-decoration:none;
}
a:link {
	text-decoration:none;
}
</style>
<style type="text/css" id="holderjs-style"></style>
</head>
<body >

<div class="container overflow-x" id="orderMain">
  <div class="row">
    <div class="col-xs-12 col-sm-12 padding_0 order">
     <div class="header_title">
       <h4><s:property value="productVO.productModel.name" /></h4>
       <p class="channel"><s:property value="productVO.productModel.startAddress"/>-<s:property value="productVO.productModelproduct.destination"/></p>
       <div class="usercenter_ico" onClick="goUserIndex()"><a href="travel/weixin/user/index.html" class="usercenter-back"></a></div>
      </div>
    </div>
  </div>
  
  <div class="row">
    <div class="col-xs-12 col-sm-12 padding_0 order_list">
      <div class="panel-group acc-v1 margin-bottom-0 " id="accordion-1">
        <div class="panel panel-default margin-bottom-10">
          <div class="panel-heading" id="starting_date">
	          <h4 class="panel-title clearfix pointer" > 
		          <span class="glyphicon glyphicon_calendar glyphicon_size pull-left"></span>
		          <span class="pull-left itineraryfonts" >选择出行日期</span>
		          <span class="pull-left itineraryfonts" id="date_content">
		          	<s:property value="productVO.productModel.defaultDateString" />
		          </span>
		          <span class="bluearrow  bluerightarrow pull-right"></span> 
	          </h4>
          </div>
        </div>
        <!-- 拼房信息 start -->
        <s:if test='productVO.productModel.hoursePrice != null && productVO.productModel.hoursePrice != 0'>
         <div class="panel panel-default margin-bottom-10" >
          <div class="panel-heading ">
            <h4 class="panel-title clearfix"> <a class="accordion-toggle clearfix "  > 
            <span class=" pull-left  position_reative">
              <div class="pull-left" onclick="choose(this,0)">
	            <span class=" pull-left  position_reative">
	              <div class="icheckbox_polaris checked" id="share_house">
	                <input type="checkbox" tabindex="22" style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;">
	                <ins style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;"></ins></div>
	              </span>
	              <span class="pull-left itineraryfonts ml_42" >同意拼房</span>
              </div>
              
              <div class="pull-left polarisNone" onclick="choose(this,1)">
	              <span class=" pull-left  position_reative" >
	              <div class="icheckbox_polaris ">
	                <input type="checkbox"  tabindex="22" style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;">
	                <ins style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;"></ins></div>
	              </span><span class="pull-left itineraryfonts ml_42" >不拼房</span>
              </div>
              </span>
            </h4>
          </div>
          
           <div  class="panel-collapse collapse in">
		   <div class="panel-body panel-body-bj">
		  	 <div class="row">
               <div class="col-xs-12 itinerary_show">
                 <p class="safe" id="agreement">根据实际情况，也有可能实在没法拼房，届时仍需补单房差，但我们将努力不让你多花钱。</p>
               </div>
             </div>
		   </div>
		  </div>
        </div>
        </s:if>
		<!-- 拼房信息 end -->
		<form id="orderForm" method="POST">
		<input type="hidden" name="startingDate" id="startingDate" value="<s:property value='productVO.productModel.defaultDateString' />" />
		<!-- 联系人信息 start -->
		<div class="panel panel-default margin-bottom-10">
		  <div class="panel-heading collapseDiv" onclick="$(this).next().collapse('toggle')">
            <h4 class="panel-title clearfix"> 
	            <a class="accordion-toggle clearfix"  >
		            <span class="glyphicon glyphicon_peoples glyphicon_size pull-left" ></span>
		            <span class="pull-left itineraryfonts">联系人信息</span>
		            <span class="bluearrow  bluedownarrow pull-right"></span>
	            </a>
            </h4>
          </div>
          <div class="panel-collapse collapse in">
            <div class="panel-body">
              <div class="row">
                <div id="contact_member_input" class="col-xs-12 itinerary_show form-horizontal">
                  <div class="form-group user_news">
                    <label class="col-sm-2 control-label col-xs-2 padding_right0" for="inputEmail3" style="padding-top:7px">姓名</label>
                    <div class="col-sm-4 col-xs-9">
                      <input type="text" placeholder="请输入姓名" name="orderVO.orderModel.phoneName" value="" class="validate[required] form-control" maxlength="20" data-prompt-position="topLeft:10">
                    </div>
                  </div>
                  
                  <div class="form-group user_news">
                    <label class="col-sm-2 control-label col-xs-2 padding_right0" for="inputPassword3" style="padding-top:7px">性别</label>
                  	<label class="radio-inline" style="width:30%;text-align:left">
				    <input type="radio" name="orderVO.orderModel.gender"  value="male" checked="checked">男
				  </label>
        	      <label class="radio-inline" style="width:30%;text-align:left">
			         <input type="radio" name="orderVO.orderModel.gender" value="female">女
			      </label>
                  </div>
                  
                  <div class="form-group user_news">
                    <label class="col-sm-2 control-label col-xs-2 padding_right0" for="inputEmail3"  style="padding-top:7px">电话</label>
                    <div class="col-sm-4 col-xs-9">
                      <input type="text" name="orderVO.orderModel.phone" placeholder="请输入电话号码" id="inputPhoneNum" value="" class="validate[required,funcCall[checkPhoneNum]] form-control"  data-prompt-position="topLeft:10">
                    </div>
                  </div>
                 
                  <div class="form-group user_news">
                    <label class="col-sm-2 control-label col-xs-2 padding_right0" for="inputEmail3" style="padding-top:7px">邮箱</label>
                    <div class="col-sm-4 col-xs-9">
                      <input type="text" placeholder="请输入邮箱"  name="orderVO.orderModel.email" value=""  class="validate[required, custom[email]] form-control" data-prompt-position="topLeft:10">
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
		</div>
		<!-- 联系人信息 end -->
		</form>
        <div class="panel panel-default margin-bottom-10">
          <div class="panel-heading collapseDiv" onclick="$(this).next().collapse('toggle')">
            <h4 class="panel-title clearfix"> 
	            <a class="accordion-toggle clearfix"  >
		            <span class="glyphicon glyphicon_peoples glyphicon_size pull-left" ></span>
		            <span class="pull-left itineraryfonts">选择人数</span>
		            <span class="bluearrow  bluedownarrow pull-right"></span>
	            </a>
            </h4>
          </div>
          <div class="panel-collapse collapse in">
            <div class="panel-body">
            <form id="collapse-One">
              <div class="row">
                <div class="col-xs-12 itinerary_show">
                  <h4 class="panel-title clearfix"> 
	                  <a class="accordion-toggle clearfix pull-left order_people"  >
		                  <span class="glyphicon glyphicon_peoples glyphicon_size pull-left" ></span>
		                  <span class="pull-left itineraryfonts text-indent">成人</span>
		                  <span class="pull-left itineraryfonts color_orange">
		                  	<s:text name="format.number">
								<s:param value="productVO.productModel.price"/>
							</s:text>
		                  </span>
	                  </a>
		              <div class="ace-spinner middle touch-spinner pull-left" style="width:40%">
		                <div class="input-group form-group">
		                  <div class="spinbox-buttons input-group-btn" onclick="downOne('adult')">
		                    <button class="btn  btn_blue" type="button"><span class="glyphicon glyphicon-minus"></span></button>
		                  </div>
	                  		<input type="text" id="adultNum" disabled="disabled" class="validate[required,custom[integer],min[1]] input-mini spinbox-input form-control input_numberbox text-center" value="1" data-prompt-position="topLeft:10">
		                  <div class="spinbox-buttons input-group-btn" onclick="addOne('adult')">
		                    <button class="btn  btn_blue" type="button"><span class="glyphicon glyphicon-plus"></span></button>
		                  </div>
		                </div>
		              </div>
           		 </h4>
                </div>
              </div>
              <s:if test='productVO.productModel.childrenPrice != null && productVO.productModel.childrenPrice != 0'>
              <div class="row">
                <div class="col-xs-12 itinerary_show">
                  <h4 class="panel-title clearfix"> 
                  <a class="accordion-toggle clearfix pull-left order_people"  >
	                  <span class="glyphicon glyphicon_peoples glyphicon_size pull-left" ></span>
	                  <span class="pull-left itineraryfonts text-indent">儿童</span>
	                  <span class="pull-left itineraryfonts color_orange">
	                  	<s:text name="format.number">
							<s:param value="productVO.productModel.childrenPrice"/>
						</s:text>
	                  </span>
                  </a>
	              <div class="ace-spinner middle touch-spinner pull-left" style="width:40%">
	                <div class="input-group form-group">
	                  <div class="spinbox-buttons input-group-btn" onclick="downOne('child')">
	                    <button class="btn  btn_blue" type="button"><span class="glyphicon glyphicon-minus"></span></button>
	                  </div>
	                  <input type="text" id="childrenNum" disabled="disabled" class="input-mini spinbox-input form-control input_numberbox text-center validate[required,custom[integer],min[0]]" value="0" data-prompt-position="topLeft:10">
	                  <div class="spinbox-buttons input-group-btn" onclick="addOne('child')">
	                    <button class="btn  btn_blue" type="button"><span class="glyphicon glyphicon-plus"></span></button>
	                  </div>
	                </div>
	              </div>
           		</h4>
                </div>
              </div>
              </s:if>
              <s:else>
              	  <input type="hidden" id="childrenNum" class="input-mini spinbox-input form-control input_numberbox text-center validate[required,custom[integer],min[0]]" value="0" data-prompt-position="topLeft:10">
              </s:else>
              </form>
            </div>
          </div>
        </div>
       	<form id="memberInfoForm" method="POST">
       	<!-- 成员信息 start -->
        <div id="memberInfo" class="panel panel-default  margin-bottom-10" style="overflow:visible">
          <div class="panel-heading " id="member_div">
            <h4 class="panel-title clearfix">
              <span class="glyphicon glyphicon_news glyphicon_size pull-left" ></span>
              <span class="pull-left itineraryfonts">成员信息 </span>
              <span class="bluearrow bluedownarrow pull-right"></span>
            </h4>
          </div>
          
          <div class="panel-collapse collapse in">
            <div class="panel-body table_news">
              <div class="row">
                <div class="col-xs-12 itinerary_show col-sm-12 padding_0">
                  <table class="table table-bordered" border="0" width="100%">
                    <tbody id="item_tbody">
                    	
                    </tbody>
                  </table>
                </div>
              </div>
            </div>
          </div>
        </div>
        <!-- 成员信息 end -->
        </form>
        <!-- 支付方式 start -->
        <div class="panel panel-default  margin-bottom-20  animated fadeInDown">
          <div class="panel-heading collapseDiv" onclick="$(this).next().collapse('toggle')">
            <h4 class="panel-title clearfix">
              <a class="accordion-toggle clearfix"  >
                <span class="glyphicon glyphicon_peoples glyphicon_size pull-left" ></span>
                <span class="pull-left itineraryfonts">选择支付方式</span>
                <span class="bluearrow  bluedownarrow pull-right"></span>
              </a>
            </h4>
          </div>
          <div class="panel-collapse collapse in" >
            <div class="panel-body message_body">
              <div class="row">
                <div class="col-xs-12 itinerary_show message_dl">
                  <dl style="margin-left: 30px;">
                    <dt class="clearfix"><input type="radio" name="paymentType" id="input_paymentType_0" class="form-control"  value="weixin" checked="checked" style="margin-right: 10px;"><span><label for="input_paymentType_0">微信支付</label></span></dt>
                    <dt class="clearfix"><input type="radio" name="paymentType" id="input_paymentType_1" class="form-control"  value="ali" style="margin-right: 10px;"><label for="input_paymentType_1">支付宝支付</label></dt>
               	  </dl>
                </div>
              </div>
            </div>
          </div>
        </div>
        <!-- 支付方式 end -->
      	
      </div>
    </div>
  </div>
  
<table class="table table-bordered" border="0" width="100%" style="display: none;">
	<tbody id="orderItem_example_adult">
		<tr id="orderItem_adult_LY_name" class="adult_tr" >
			<td class="light_blue" style="text-align: right; vertical-align: middle;">姓名</td>
			<td class="form-group user_news">
				<div class="form-group user_news">
					<div class="col-sm-4 col-xs-9">
						<input type="text" placeholder="请输入姓名" id="orderItem_adult_LY_name_input" name="orderVO.orderItemModelList[LY_index].memberName" value="" class="validate[required] form-control" maxlength="20" data-prompt-position="topLeft:10">
					</div>
				</div>
			</td>
		</tr>
		<tr id="orderItem_adult_LY_gender">
			<td class="light_blue" style="text-align: right; vertical-align: middle">性别</td>
			<td class="form-group user_news">
				<div class="form-group user_news" style="margin-top: 8px; margin-bottom: 7px;">
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].gender" id="adult_LY_index_gender_0" value="male" checked="checked">男
					</label>
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].gender" id="adult_LY_index_gender_1" value="female">女
					</label>
				</div>
			</td>
		</tr>
		<tr id="orderItem_adult_LY_isAdult">
			<td class="light_blue" style="text-align: right; vertical-align: middle">年龄</td>
			<td>
				<div class="form-group user_news" style="margin-top: 8px; margin-bottom: 7px;">
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].isAdult" id="adult_LY_index_isAdult" value="true" checked="checked">成人
					</label>
				</div>
			</td>
		</tr>
	</tbody>
</table><!-- orderItem_example_adult end -->
<table class="table table-bordered" border="0" width="100%" style="display: none;">
	<tbody id="orderItem_example_children">
		<tr id="orderItem_child_LY_name" class="children_tr" >
			<td class="light_blue" style="text-align: right; vertical-align: middle">姓名</td>
			<td class="form-group user_news">
				<div class="form-group user_news">
					<div class="col-sm-4 col-xs-9">
						<input type="text" placeholder="请输入姓名" id="orderItem_child_LY_name_input" name="orderVO.orderItemModelList[LY_index].memberName" value="" class="validate[required] form-control" maxlength="20" data-prompt-position="topLeft:10">
					</div>
				</div>
			</td>
		</tr>
		<tr id="orderItem_child_LY_gender">
			<td class="light_blue" style="text-align: right; vertical-align: middle">性别</td>
			<td class="form-group user_news">
				<div class="form-group user_news" style="margin-top: 8px; margin-bottom: 7px;">
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].gender" id="child_LY_index_gender_0" value="male" checked="checked">男
					</label>
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].gender" id="child_LY_index_gender_1" value="female" >女
					</label>
				</div>
			</td>
		</tr>
		<tr id="orderItem_child_LY_isAdult">
			<td class="light_blue" style="text-align: right; vertical-align: middle">年龄</td>
			<td>
				<div class="form-group user_news" style="margin-top: 8px; margin-bottom: 7px;">
					<label class="radio-inline" style="width:30%;text-align:left">
						<input type="radio" name="orderVO.orderItemModelList[LY_index].isAdult" id="child_LY_index_isAdult" value="false" checked="checked">儿童
					</label>
				</div>
			</td>
		</tr>
	</tbody>
</table><!-- orderItem_example_children end -->

    <div id="buyNow">
	  <div class="row">
	    <div class="col-xs-12 col-sm-12">
	      <div class="total">总计：<span id="totalPrice"><s:text name="format.number"><s:param value="productVO.productModel.price"/></s:text></span></div>
	    </div>
	  </div>
      
      <div class="row" >
        <div class="col-xs-12 col-sm-12 term_box">
          <div class="total term">
            <div class="pull-left" onclick="agreementContract(this)">
	          <span class=" pull-left  position_reative">
	            <div class="icheckbox_polaris">
	              <input type="checkbox" tabindex="22" style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;">
	              <ins style="position: absolute; top: 10%; left: 10%; display: block; width: 80%; height: 80%; margin: 0px; padding: 0px; background: none repeat scroll 0% 0% rgb(255, 255, 255); border: 0px none; opacity: 0;"></ins>
	            </div>
	          </span>
	          <span class="pull-left itineraryfonts ml_42 total term" style="color: #000; font-size: 1.05em; font-weight: normal;">我已阅读并同意<i onclick="$('#agreement_content_div').toggle();choose();">《风客预定条款》</i></span>
            </div>
		  </div>
	    </div>
      </div>
      
      <div id="qun_zxing" align="left">
		<div id="agreement_content_div" style="display: none;margin-bottom: 10px;">
			<h3 style="text-align: center;">《线下活动免责声明》</h3>
			<p style="text-indent: 2em;">特别提示：风客主题旅行的旅游产品均由具备资质的旅游产品供应商提供。旅游产品供应商充分借用风客主题旅行的网络预订平台，推出全方位的旅游产品，产品的行程安排以及合同签订都是由合作旅游产品供应商为您提供。风客主题旅行作为您获取旅游产品的平台，本协议的签署并不意味着风客主题旅行成为旅游产品交易的参与者，对前述交易风客主题旅行仅提供技术支持，不对供应商行为的合法性、有效性及旅游产品的真实性、合法性及有效性作任何明示或暗示的担保。在预订由风客主题旅行为您展示的旅游产品前，请您仔细阅读本须知，并注意本须知及产品页面中的其它重要条款也作为双方协议的补充内容。当您开始预订旅游产品时，即表明您已经仔细阅读并接受本协议的所有条款。</p>
			<p style="font-weight: bolder;text-align: center;">第一条 相关概念及注解</p>
			<p style="text-indent: 2em;">1.出境旅游产品：旅游度假目的地为中国已开放的旅游目的地国家及中国台湾、香港和澳门地区，从出发地到度假目的地往返交通票、目的地酒店住宿。、旅行用车及其他可选择附加旅游产品。</p>
			<p style="text-indent: 2em;">2.自助游旅游产品：该类产品包含前往度假目的地的往返机票、火车票、目的地住宿酒店、旅行用车及其它可选配的接送机、门票等项目的部分或全部。</p>
			<p style="text-indent: 2em;">3.半自助游旅游产品：以酒店＋交通＋一半团队游＋一半自由行＋个性化可选服务为核心，既有充足的自由活动时间，又有专业导游带您游览经典景区，且不含任何强制购物和自费项目。</p>
			<p style="text-indent: 2em;">4.团队游旅游产品：以酒店＋交通＋特色餐食＋景点门票＋旅游用车＋全程导游＋签证（海外）为核心，对行程、交通方式、食宿标准、游览项目均有固定安排，且有专职导游和专车带您游览经典景点。该类产品对成团人数有一定的要求。</p>
			<p style="text-indent: 2em;">5.游客：指通过风客主题旅行预订旅游产品供应商在风客主题旅行上提供的旅游产品的用户，游客在风客主题旅行上预订旅游产品成功后，游客和旅游产品供应商之间建立合同关系。</p>
			<p style="text-indent: 2em;">6. 酒店入住登记要求：登记入住酒店的客人中至少要有1人超过18周岁，即未满18周岁的客人必须由18周岁以上的客人帮其办理酒店入住手续。</p>
			<p style="font-weight: bolder;text-align: center;">第二条 旅游产品内容及其标准</p>
			<p style="text-indent: 2em;">1.旅游产品内容主要包含：酒店、飞机票、火车票、旅行用车、目的地接待服务及其他服务。具体产品的最终包含内容以确认的订单约定内容为准。</p>
			<p style="text-indent: 2em;">2.风客主题旅行关于旅游产品的行程推荐仅为友情提示，不能作为约定条款。</p>
			<p style="text-indent: 2em;">3.旅游产品中约定的产品和服务内容，均为经过风客主题旅行严格考评筛选出的具备相关资质的供应商提供，风客主题旅行只对其经营资质的合法性承担责任，不对其在您消费过程中可能涉及的具体产品和服务内容承担责任。</p>
			<p style="font-weight: bolder;text-align: center;">第三条 旅游产品价格</p>
			<p style="text-indent: 2em;">风客主题旅行页面展示的产品价格仅为参考价格，由于旅游产品价格的波动性，旅游产品供应商可能因为机票、酒店的价格变动而适度调整其在风客主题旅行上已公布的旅游产品的价格。您预订的所有旅游产品的价格，以旅游产品供应商与您最后确认的金额为准。</p>
			<p style="font-weight: bolder;text-align: center;">第四条 订单生效</p>
			<p style="text-indent: 2em;">您在风客主题旅行预订产品成功后，旅游产品供应商工作人员会给您关于订单的确认，只要您在预订付款期前（具体参照与旅游供应商的具体约定）付清供应商给您确认的应付款时，您确认的订单即生效。但如您未按要求在预订付款期前付清相关费用，而此时风客主题旅行为您预留的产品的价格、内容或标准等有发生变化，风客主题旅行对此不承担任何责任。 订单生效，即代表您与旅游产品供应商的合作意向已经达成，你的变更、解除旅游产品等的需求，将受到本协议第五条、第六条等相关条款的约束。订购合同成立后，您应按订单中约定的时间或时段准时出发，酒店应按确定日在确定时间后入住。如您未准时出发或未能按时入住所订酒店，则视您的这种行为构成违约，您应承担由此导致的损失并按照约定支付违约金。</p>
			<p style="font-weight: bolder;text-align: center;">第五条 您主动更改已生效订单</p>
			<p style="text-indent: 2em;">订单生效后，您若需要更改该订单内的任何项目，请务必在旅游产品行程开始前通知您的更改需求。我们会尽量满足您的需求，但您必须全额承担因变更带来的损失及可能增加的费用。若您所预订的产品在目的地停留的日期部分或全部处在国家法定节假日或其它部分国际性、国家性、地方性重大节日期间，鉴于资源的特殊状况，已生效订单不可进行任何更改。</p>
			<p style="font-weight: bolder;text-align: center;">第六条 您主动解除已生效订单</p>
			<p style="text-indent: 2em;">订单生效后，若要主动解除已生效订单，您必须在旅游产品行程开始前通知您需要解除的订单，包括放弃整张订单的全部内容、减少出行人数等。我们会帮您立即取消。但您必须承担处理该订单已经支出的一切费用。包括护照成本手续费、实际签证费、订房损失费、国际国内机票及其它车船交通费用等。</p>
			<p style="text-indent: 2em;">1.送签证后取消（一般是收到护照后的下一个工作日送签），收取全部签证费用。</p>
			<p style="text-indent: 2em;">2.机票一经开出如退票或签转，您将根据航空公司的规定，承担相应的退票或更改损失。</p>
			<p style="text-indent: 2em;">3.车船票一经开出如退票，您须承担相应的退票或更改损失。</p>
			<p style="text-indent: 2em;">4.您预订的酒店需在入住前取消，如在产品订单中有特别规定的，您需根据约定承担相应的酒店预订损失。如您取消预订或行程有变化，请尽早通知，以避免不必要的损失。</p>
			<p style="text-indent: 2em;">5.产品订单中约定违约金的情况,您还需按约定承担相应的违约金。</p>
			<p style="font-weight: bolder;text-align: center;">第七条 您的权利和义务</p>
			<p style="text-indent: 2em;">1.您应确保出行人身体条件适合本次外出旅游度假，如出行人为孕妇或有心脏病、高血压、呼吸系统疾病等病史，请在征得医院专业医生同意后出行。</p>
			<p style="text-indent: 2em;">2.您保证提供给风客主题旅行的证件、通讯联络方式、配送地址等相关资料均真实有效。</p>
			<p style="text-indent: 2em;">3.度假期间，您应尊重当地的宗教信仰、民族习惯和风土人情，自觉保护当地自然环境。</p>
			<p style="text-indent: 2em;">4.您在旅游过程中如对旅游产品供应商的服务质量有异议，应积极与旅游产品供应商沟通积极争取在旅游过程中解决。</p>
			<p style="text-indent: 2em;">5.您可以选择通过风客主题旅行或旅游产品供应商投诉电话进行投诉。</p>
			<p style="text-indent: 2em;">6.如您不遵守《风客主题旅行用户服务协议》或本须知的规定，恶意干扰风客主题旅行平台的正常运营，恶意预订、更改或退订旅游产品，或者恶意向第三方机构投诉风客主题旅行或旅游产品供应商，风客主题旅行保留追究您个人责任的权利。</p>
			<p style="font-weight: bolder;text-align: center;">第八条 涉及第三方的相关责任</p>
			<p style="text-indent: 2em;">第三方指在办理出境旅游度假事宜中涉及的发照机关、签证机关、航空公司、保险公司、境外接待社、饭店、同行团友及其他相关机构、企业和个人。对于风客主题旅行无法控制，您与第三方出现的下列情况，风客主题旅行应协助办理，结果由您承担。</p>
			<p style="text-indent: 2em;">1.您在旅行中应注意人身财产安全，妥善保管自己的证件及行李物品， 如果发生人身意外、伤害或随身携带行李物品遗失、被盗、被抢等情况，风客主题旅行会积极协助办理，但无赔偿之责任；补办证件所产生的费用，由您自行承担。解决的依据应以相关机构（如航空公司、酒店、保险公司）的规定为准。您必须保留有关单据和证明文件。</p>
			<p style="text-indent: 2em;">2.您违反相关国家或地区的法律、法规而被罚、被拘留、遣返及被追究其他刑事、民事责任的，您应依法承担相关责任和费用。</p>
			<p style="text-indent: 2em;">3.是否发放护照、签证，是否准予出入境，系有关国家机构之权力，您应按要求提供真实的资料，供应商可协助办理。但因您自身原因导致不能及时办理护照、签证而影响行程的，以及被相关机关拒发护照、签证或拒绝入境的，您应承担全部责任，并应支付供应商的损失及费用。</p>
			<p style="text-indent: 2em;">4.因有关机构政策调整造成您的护照、签证延误，您需按约定承担已发生的费用。</p>
			<p style="text-indent: 2em;">5.您违反我国及前往国家（地区）的有关规定，携带过量货币、物品或违禁品而产生的一切后果由您自行承担。</p>
			<p style="font-weight: bolder;text-align: center;">第九条 不可抗力</p>
			<p style="text-indent: 2em;">1.因不可抗力(包括地震、台风、雷击、雪灾、水灾、火灾等自然原因,以及战争、政府行为、黑客攻击、电信部门技术管制等原因)和意外事件等原因不能履行或不能继续履行已生效订单约定内容的，双方均不承担违约责任，但法律另有规定的除外。</p>
			<p style="text-indent: 2em;">2.如果发生航班延误、航班取消等特殊情况，请及时联系产品供应商，供应商为您联系您即将入住的酒店，尽量争取减少您的损失。</p>
			<p style="text-indent: 2em;">3.如果由于航空公司燃油涨价或是临时调价而导致的航线价格上涨，对于已成交的订单，不再向您收取涨价费用；对于已确认但未付款和未确认的订单，则以新价格为准。</p>
		</div>
	</div>
      
	<div class="row">
	  <div class="col-xs-12 col-sm-12  order_bottombtn padding_10">
	    <a class="btn submit_orders margin_right0" id="submit_button" type="button" disabled="disabled" style="background:#c6c6c6;">立即购买</a>
	  </div>
	</div>
  </div>
  </div>

    <!--电话资询弹出框-->
    <div class=" modal-sm modal_news animated fadeInLeftBig mobileModel"  style="display: none"> 
      <div class="modal-content">
        <div class="modal-header">
          <h4 id="mySmallModalLabel" class="modal-title">提示</h4>
                  <p id="alert_message_p">数量和成员不对应</p>
        </div>
        <div class="modal-body clearfix modal_btngroup">
           <button class="sure" data-dismiss="modal" type="button" style="width:100%;border-left:0 none;"><a>确定</a></button>
        </div>
      </div><!-- /.modal-content -->
    </div><!-- /.modal-dialog -->
          <!--电话资询弹出框-->
<form id="create_order_form" action="travel/weixin/order/createOrder.action" method="POST">
	<input type="hidden" id="param_productId" name="productVO.productModel.id" value="<s:property value='productVO.productModel.id' />" />
	<input type="hidden" id="param_goDateString" name="param_goDateString" value="<s:property value='productVO.productModel.defaultDateString' />" />
	<input type="hidden" id="param_isShareHouse" name="orderVO.orderModel.isShareHouse" value="true" />
	<input type="hidden" id="param_adultNum" name="orderVO.orderModel.adultNum" value="1" />
	<input type="hidden" id="param_childrenNum" name="orderVO.orderModel.childrenNum" value="0" />
	<input type="hidden" id="param_paymentType" name="param_paymentType" value="weixin" />
</form>
</body>
	<script type="text/javascript">
		var totalNum = 1; // 总人数
		var totalIndex = 0; // 人数索引
		var adultPrice = "<s:property value='productVO.productModel.price' />";
		var childrenPrice = "<s:property value='productVO.productModel.childrenPrice' />";
		var hoursePrice = "<s:property value='productVO.productModel.hoursePrice' />";
		
		Date.prototype.Format = function (fmt) { //author: meizz 
		    var o = {
		        "M+": this.getMonth() + 1, //月份 
		        "d+": this.getDate(), //日 
		        "h+": this.getHours(), //小时 
		        "m+": this.getMinutes(), //分 
		        "s+": this.getSeconds(), //秒 
		        "q+": Math.floor((this.getMonth() + 3) / 3), //季度 
		        "S": this.getMilliseconds() //毫秒 
		    };
		    if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
		    for (var k in o)
		    if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
		    return fmt;
		}
		
		$(function(){
			var dateStr="<s:property value='productVO.productModel.startingDate' />";
			var arrDate=dateStr.split(",");
			var arrDate1=[];
			for(var i=0;i<arrDate.length;i++){
				var d=new Date(arrDate[i]);
				arrDate1.push(d);
			}
			
			if("<s:property value='productVO.productModel.defaultDateString' />"&&"<s:property value='productVO.productModel.defaultDateString' />"){
			$('#startingDate').mobiscroll().calendar({
				theme: 'mobiscroll',
			    lang: 'zh',
			    display: 'bottom',
			    dateFormat:'yy-mm-dd',
			    minDate:new Date("<s:property value='productVO.productModel.defaultDateString' />"),
			    maxDate:new Date("<s:property value='productVO.productModel.maxDateStr' />"),
			    controls: ['calendar'],
			    invalid: ['w0','w1','w2','w3','w4','w5','w6'],
			    valid:arrDate1,
		        onSelect: function (valueText, inst) {
		            var selectedDate = inst.getVal(); // Call the getVal method
		            $("#date_content").empty();
		        	$("#date_content").text(new Date(selectedDate).Format("yyyy-MM-dd"));
		        }
		    });    
			
	       
		  $('#starting_date').click(function(){
	          $('#startingDate').mobiscroll('show'); 
	          return false;
		  });
		    
		}
		    
		$('input:radio').iCheck({
			checkboxClass : 'icheckbox_flat-blue',
			radioClass : 'iradio_flat-blue',
			increaseArea : '100%'
		});
		
		app.validateEngine('form[id=orderForm]');
		app.validateEngine('form[id=memberInfoForm]');
	    });
		
        function countPrice(){
        	var isShareHouse;
        	var adultNum=$("#adultNum").val();
        	var childrenNum=$("#childrenNum").val();
        	if($("#share_house").hasClass("checked")){
        		isShareHouse="true";
        	}else{
        		isShareHouse="false";
        	}
        	
        	$.ajax({
				url: "travel/weixin/order/countPrice.action?productVO.productModel.id=<s:property value='productVO.productModel.id'/>&adultNum="+adultNum+"&childrenNum="+childrenNum+"&isShareHouse="+isShareHouse,
				type: "GET",
				dataType: "json",
				cache: false,
				async:true,
				success: function(data) {
					if(data){
						$("#totalPrice").text(currency(data, true));
					}
				}
			});
        }
        
        // $(obj).closest('tr').hasClass('adult_tr')
        
        // 增加人员
        function addOne(type){
       		var re = new RegExp("LY_index","g");
       		var re1 = new RegExp("LY", "g");
       		var adultNum = parseInt($("#adultNum").val());
       		var childrenNum = parseInt($("#childrenNum").val());
        	if('adult' == type) {
        		adultNum ++;
        		// orderItem_example_adult
        		$('#item_tbody').append($('#orderItem_example_adult').html().replace(re, totalIndex).replace(re1, adultNum));
        		$("#adultNum").val(adultNum);
        		$("#orderItem_adult_" + adultNum + "_name_input").removeClass();
            	$("#orderItem_adult_" + adultNum + "_name_input").addClass("validate[required] form-control");
        	} else if('child' == type) {
        		childrenNum ++;
        		// orderItem_example_children
        		$('#item_tbody').append($('#orderItem_example_children').html().replace(re, totalIndex).replace(re1, childrenNum));
        		$("#childrenNum").val(childrenNum);
        		$("#orderItem_child_" + childrenNum + "_name_input").removeClass();
            	$("#orderItem_child_" + childrenNum + "_name_input").addClass("validate[required] form-control");
        	}
        	if(adultNum + childrenNum > 1) {
        		$("#member_div").attr("onclick","$(this).next().collapse('toggle')");
        	}
        	
        	totalIndex ++;
        	
        	countPrice();
        	
        	$('input:radio').iCheck({
    			checkboxClass : 'icheckbox_flat-blue',
    			radioClass : 'iradio_flat-blue',
    			increaseArea : '100%'
    		});
        }
        // 减少人员
        function downOne(type){
       		var adultNum = parseInt($("#adultNum").val());
       		var childrenNum = parseInt($("#childrenNum").val());
        	if('adult' == type) {
        		if(adultNum > 1) {
        			$('#orderItem_adult_' + adultNum + '_name').remove();
        			$('#orderItem_adult_' + adultNum + '_gender').remove();
        			$('#orderItem_adult_' + adultNum + '_isAdult').remove();
        			$("#adultNum").val(--adultNum);
        		}
        	} else if('child' == type) {
        		if(childrenNum > 0) {
        			$('#orderItem_child_' + childrenNum + '_name').remove();
        			$('#orderItem_child_' + childrenNum + '_gender').remove();
        			$('#orderItem_child_' + childrenNum + '_isAdult').remove();
        			$("#childrenNum").val(--childrenNum);
        		}
        	}
        	if(adultNum + childrenNum <= 1) {
        		$("#member_div").attr("onclick","");
        	}
        	countPrice();
        }
        
        function choose(obj,status){
        	var $this=$(obj);
        	var input=$this.find("input");
        	input.parent().addClass('checked');
			if(status==0){
				$this.next().find("input").parent().removeClass('checked');
				$("#agreement").empty();
        		$("#agreement").append("根据实际情况，也有可能实在没法拼房，届时仍需补单房差，但我们将努力不让你多花钱");
        		$("input[name=isShareHouse]").val(true);
        	}else{
        		$this.prev().find("input").parent().removeClass('checked');
        		$("#agreement").empty();
        		$("#agreement").append('需要补单房差 <s:property value="productVO.productModel.hoursePrice" />元，如需加床或转为三人间请致电：<i><a href="tel:<s:property value='productVO.productModel.phone'/>"><s:property value="productVO.productModel.phone"/></a></i>');
        		$("input[name=isShareHouse]").val(false);
        	}
        	
        	countPrice();
        }
        
    	$(".mobileModel").click(function(){
    		$(".mobileModel").hide();
    	});
    	
    	
    	function checkPhoneNum(){
    		var inputPhoneNum = $("#inputPhoneNum").val();
      		var result;
    		if(inputPhoneNum.trim()=="") {
    	 		
    	 	} else {
    	 		if(typeof(inputPhoneNum)=="undefined")
    			return false;
    			if(inputPhoneNum=="" || inputPhoneNum==null){
    				return false;
    			}
    			
    			if(inputPhoneNum.length!=11){
    				result = "请输入11位手机号码";
    			}
    			
    			var myreg = /^1[3-9]{1}[0-9]{1}\d{8}$/;
    			if(!myreg.test(inputPhoneNum)){
    				result = "请输入合法的手机号码";
    			}
    			if(result) return result;
    	 	}
    		
    	}
    	
    	function agreementContract(obj) {
    		var $this=$(obj);
        	var input=$this.find("input");
        	if(input.parent().hasClass('checked')) {
        		input.parent().removeClass('checked');
        		$('#submit_button').attr('disabled', 'disabled');
    			$('#submit_button').unbind('click');
    			$('#submit_button').css('background', '#c6c6c6 none repeat scroll 0 0');
        	} else {
	        	input.parent().addClass('checked');
	        	$('#submit_button').bind('click', buyNow);
    			$('#submit_button').css('background', '#22cbc4 none repeat scroll 0 0');
    			$('#submit_button').removeAttr('disabled');
        	}
    	}
    	
        function buyNow(){
        	var result = $('form[id=orderForm]').validationEngine('validate');
        	var result1 = $('form[id=memberInfoForm]').validationEngine('validate');
        	
           	if(!result || !result1){
           		return false;
           	}
    	    $("#param_goDateString").attr('value', $.trim($("#date_content").text()));
   	    	$("#param_adultNum").val(parseInt($("#adultNum").val()));
   	    	$("#param_childrenNum").val(parseInt($("#childrenNum").val()));
   	    	if($("#share_house").hasClass("checked")){
   	    		$("#param_isShareHouse").val(true);
        	}else{
        		$("#param_isShareHouse").val(false);
        	}
   	    	$('input[type=radio][name=paymentType]').each(function() {
   	    		if($(this).is(":checked")) {
   	    			//alert($(this).val());
		   	    	$('#param_paymentType').attr('value', $(this).val());
   	    		}
   	    	});
           	// 成员信息
   			if($('#item_tbody').find('input')) {
	   			$('#item_tbody').find('input').each(function() {
	   				if('radio' == $(this).attr('type') || 'checkbox' == $(this).attr('type')) {
	   					if($(this).is(":checked")) {
	   	   	    			$('#create_order_form').append('<input type="hidden" name="' + $(this).attr('name') + '" value="' + $(this).val() + '" />');
	   	   	    		}
	   				} else {
	   					$('#create_order_form').append('<input type="hidden" name="' + $(this).attr('name') + '" value="' + $(this).val() + '" />');
	   				}
	   			});
   			}
           	
   			$('#contact_member_input').find('input').each(function() {
   				if('radio' == $(this).attr('type') || 'checkbox' == $(this).attr('type')) {
   					if($(this).is(":checked")) {
   	   	    			$('#create_order_form').append('<input type="hidden" name="' + $(this).attr('name') + '" value="' + $(this).val() + '" />');
   	   	    		}
   				} else {
   					$('#create_order_form').append('<input type="hidden" name="' + $(this).attr('name') + '" value="' + $(this).val() + '" />');
   				}
   			});
   	    	
           	//$(".mobileModel").show();
           	//return false;
           	
           	$('#submit_button').attr("disabled","disabled");
   			$('#submit_button').unbind('click');
   			$('#submit_button').css('background', '#c6c6c6 none repeat scroll 0 0');
   			
   			// alert($('#create_order_form').find('input').serialize());
   			
           	$('#create_order_form').submit();
        }
        
        function goUserIndex(){
			window.location.href = "travel/weixin/user/index.html";
		}
        
        $(".collapseDiv").click(function(){
			if($(this).find(".bluearrow").hasClass("blueuparrow")){
				$(this).find(".bluearrow").removeClass("blueuparrow").addClass("bluedownarrow");
			}else{
				$(this).find(".bluearrow").removeClass("bluedownarrow").addClass("blueuparrow");
			}
		});
        
	</script>
</html>